package rest.jbpm.wrappers.refs;

import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlType;


@XmlType(name="definition")
public class DefinitionRef {
	
	private static String base;
	private String definitionId;

	protected DefinitionRef() {

	}
	
	public DefinitionRef(String definitionId, String baseUri) {
		
		this.definitionId = definitionId;
		this.base = baseUri;
	}
	
	@XmlAttribute(name="ref", required=true)
	public String getDeploymen() {
		return base + "repo/definition/" + definitionId;
	}

}